use strict;
use warnings;

our ${FTPUSER} = $ENV{FTPUSER}  || die "FTPUSER NOT SET";
our ${BASEDIR} = $ENV{BASEDIR}  || die "BASEDIR NOT SET";
our ${SECRET}  = $ENV{SECRET}   || die "SECRET NOT SET";
our ${DATABASE}= $ENV{DATABASE} || die "DATABASE NOT SET";
our ${MAILFROM}= $ENV{MAILFROM} || die "MAILFROM NOT SET";
our ${DBUSER}  = $ENV{DBUSER}   || die "DBUSER NOT SET";
our ${PASSWORD}= $ENV{PASSWORD} || die "PASSWORD NOT SET";

#run the replacements
while (<>)
{
    s/\§FTPUSER\§/${FTPUSER}/g;
s/§FTPASS§/${FTPUSER}/g;
s/§BASEDIR§/${BASEDIR}/g;
s/§SECRET§/${SECRET}/g;
s/§DATABASE§/${DATABASE}/g;
s/§MAILFROM§/${MAILFROM}/g;
s/§DBUSER§/${DBUSER}/g;
s/§PASSWORD§/${PASSWORD}/g;
print "$_";

}
